package pers.youqu.item.service;

import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.stereotype.Service;
import pers.youqu.common.dto.PageDTO;
import pers.youqu.item.dto.SpecParamDTO;
import pers.youqu.item.dto.SpuDTO;
import pers.youqu.item.po.Spu;

import java.util.List;

/**
 * @author Jason
 * @version 1.0.0
 * @date 2020/12/7 16:06
 * @Description TODO
 */
public interface SpuService extends IService<Spu> {
    List<SpecParamDTO> findSpuAllParamBySpuId(Long spuId, Boolean searching);

    PageDTO<SpuDTO> findSpuByPage(Long brandId, Long categoryId, Long spuId, Integer page, Integer rows, Boolean saleable);

    SpuDTO findSpuAllBySpuId(Long spuId);

    SpuDTO findSpuBySpuId(Long spuId);


    void updateSpuSaleable(Long spuId, Boolean saleable);

    void addSpu(SpuDTO spuDTO);

    void updateSpu(SpuDTO spuDTO);
}
